package com.itheima.day01.managerTest.entry;

import com.itheima.day01.managerTest.controller.OtherStudentController;
import com.itheima.day01.managerTest.controller.TeacherController;

import java.util.Scanner;

public class InfoManagerEntry {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        while(true){
            System.out.println("--------欢迎使用黑马信息管理系统--------");
            System.out.println("1.学生管理  2.老师管理  3.退出");
            System.out.println("请输入您的选择:");
            String choice = sc.next();
            switch(choice){
                case "1":
                    OtherStudentController studentController = new OtherStudentController();
                    studentController.start();
                    break;
                case "2":
                    TeacherController teacherController = new TeacherController();
                    teacherController.start();
                    break;
                case "3":
                    System.out.println("欢迎您的使用！");
                    // 退出当前正在运行的JVM虚拟机
                    System.exit(0);
                default:
                    System.out.println("输入有误，请重新选择：\n");
                    break;
            }
        }

    }
}
